package cn.wolfcode.trip.base.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Getter;
import lombok.Setter;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
@Setter
@Getter
public class PersonMessage {
    private Long id;        //id

    private User sourceUser;//发私信的用户

    private User targetUser;//收私信的用户
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date time;      //发送的时间

    private String content;//发送的内容

    private Integer state = 0;//状态: 未读0(默认)/已读


}